import 'package:kkhousekeep/generated/json/base/json_convert_content.dart';
import 'package:kkhousekeep/models/member_list_entity.dart';

MemberListEntity $MemberListEntityFromJson(Map<String, dynamic> json) {
	final MemberListEntity memberListEntity = MemberListEntity();
	final int? code = jsonConvert.convert<int>(json['code']);
	if (code != null) {
		memberListEntity.code = code;
	}
	final MemberListObj? obj = jsonConvert.convert<MemberListObj>(json['obj']);
	if (obj != null) {
		memberListEntity.obj = obj;
	}
	final String? msg = jsonConvert.convert<String>(json['msg']);
	if (msg != null) {
		memberListEntity.msg = msg;
	}
	return memberListEntity;
}

Map<String, dynamic> $MemberListEntityToJson(MemberListEntity entity) {
	final Map<String, dynamic> data = <String, dynamic>{};
	data['code'] = entity.code;
	data['obj'] = entity.obj.toJson();
	data['msg'] = entity.msg;
	return data;
}

MemberListObj $MemberListObjFromJson(Map<String, dynamic> json) {
	final MemberListObj memberListObj = MemberListObj();
	final List<MemberListObjList>? list = jsonConvert.convertListNotNull<MemberListObjList>(json['list']);
	if (list != null) {
		memberListObj.list = list;
	}
	return memberListObj;
}

Map<String, dynamic> $MemberListObjToJson(MemberListObj entity) {
	final Map<String, dynamic> data = <String, dynamic>{};
	data['list'] =  entity.list.map((v) => v.toJson()).toList();
	return data;
}

MemberListObjList $MemberListObjListFromJson(Map<String, dynamic> json) {
	final MemberListObjList memberListObjList = MemberListObjList();
	final int? id = jsonConvert.convert<int>(json['id']);
	if (id != null) {
		memberListObjList.id = id;
	}
	final String? name = jsonConvert.convert<String>(json['name']);
	if (name != null) {
		memberListObjList.name = name;
	}
	final int? sex = jsonConvert.convert<int>(json['sex']);
	if (sex != null) {
		memberListObjList.sex = sex;
	}
	final String? iDCardType = jsonConvert.convert<String>(json['iDCardType']);
	if (iDCardType != null) {
		memberListObjList.iDCardType = iDCardType;
	}
	final String? iDCard = jsonConvert.convert<String>(json['iDCard']);
	if (iDCard != null) {
		memberListObjList.iDCard = iDCard;
	}
	final String? phone = jsonConvert.convert<String>(json['phone']);
	if (phone != null) {
		memberListObjList.phone = phone;
	}
	final String? image = jsonConvert.convert<String>(json['image']);
	if (image != null) {
		memberListObjList.image = image;
	}
	final String? relationship = jsonConvert.convert<String>(json['relationship']);
	if (relationship != null) {
		memberListObjList.relationship = relationship;
	}
	return memberListObjList;
}

Map<String, dynamic> $MemberListObjListToJson(MemberListObjList entity) {
	final Map<String, dynamic> data = <String, dynamic>{};
	data['id'] = entity.id;
	data['name'] = entity.name;
	data['sex'] = entity.sex;
	data['iDCardType'] = entity.iDCardType;
	data['iDCard'] = entity.iDCard;
	data['phone'] = entity.phone;
	data['image'] = entity.image;
	data['relationship'] = entity.relationship;
	return data;
}